<?php

namespace common\base;

use Yii;
use yii\behaviors\TimestampBehavior;
use yii\db\ActiveRecord;

/**
 * @author Au zn <690550322@qq.com>
 * @since Full version
 */
class BaseBackendActiveRecord extends ActiveRecord
{
	const IS_DEL = 1;

	
	public static function find()
	{
		return new BaseBackendCommentQuery(get_called_class());
	}

	/**
	 * 时间设置
	 * */
	public function behaviors()
	{
		return [
			TimestampBehavior::className(),
		];
	}
    /**
     * 提示信息
     * @param $type
     * @param $content
     */
    public function showMessage($type, $content)
    {
        return Yii::$app->getSession()->setFlash($type, $content);
    }
}
